<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <script src="/dev/asset/jquery/jquery-3.5.1.min.js"></script>
    <link rel="stylesheet" type="text/css" href="/dev/asset/bootstrap/bootstrap.css">
    <script src="/dev/asset/bootstrap/bootstrap.min.js"></script>
    <script src="/dev/asset/js/comMsg.js"></script>
    <link rel="stylesheet" type="text/css" href="/dev/asset/css/comMsg.css">
    <script type="text/javascript"
            src="https://api.map.baidu.com/api?v=1.0&&type=webgl&ak=fNTKsHabAB1DEc7K2SLh67LdjokoCr8B">
    </script>
    <title>公司详情</title>
</head>

<body>
<div id="box">
    <!-- 导航栏 -->
    <div class="headerBox">
        <%@ include file="../../asset/common/header.jsp" %>
    </div>

    <div class="company-banner">
        <div class="home-inner">
            <div class="home_left">
                <div><img src="${companyMsg.icon}" alt="" width="103px" height="103px"></div>
                <div>
                    <h1>${companyMsg.name}</h1>
                    <span><c:choose>
                        <c:when test="${companyMsg.collectmoneyState==0}">
                            未融资
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==1}">
                            天使轮
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==2}">
                            A轮
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==3}">
                            B轮
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==4}">
                            C轮
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==5}">
                            D轮
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==6}">
                            已上市
                        </c:when>
                        <c:when test="${companyMsg.collectmoneyState==7}">
                            不需要融资
                        </c:when>

                    </c:choose>·<c:choose>
                        <c:when test="${companyMsg.peopleCounts==0}">
                            0-20人
                        </c:when>
                        <c:when test="${companyMsg.peopleCounts==1}">
                            20-99人
                        </c:when>
                        <c:when test="${companyMsg.peopleCounts==2}">
                            100-499人
                        </c:when>
                        <c:when test="${companyMsg.peopleCounts==3}">
                            500-999人
                        </c:when>
                        <c:when test="${companyMsg.peopleCounts==4}">
                            1000-9999人
                        </c:when>
                        <c:when test="${companyMsg.peopleCounts==5}">
                            10000人以上
                        </c:when>
                    </c:choose>·${companyMsg.kind}</span>
                </div>
            </div>
            <div class="home_right">
                <div>
                    <span>${jobCounts}在招职位</span>
                    <span> ${hrCounts}位boss</span>
                    <div class="Jian">
                        <span>完善在线简历</span>
                    </div>

                </div>
            </div>
        </div>
    </div>

    <div class="companymsg_middle">
        <div class="companymsg_middle_msg">

            <div class="comMsg_msg1">
                <h2>公司简介</h2>
                <div class="comMsg_msg1_msg">
                    ${companyMsg.companyMsg}
                </div>
            </div>

            <div class="comMsg_msg1">
                <h2 class="businessMsg_top">工商信息</h2>
                <div class="businessMsg">
                    <ul class="businessMsg_ul">
                        <li>
                            <span>公司名称:</span>
                            <div>${businessmsg.companyName}</div>
                        </li>
                        <li>
                            <span>法定法人:</span>
                            <div>${businessmsg.boss}</div>
                        </li>
                        <li>
                            <span>成立时间:</span>
                            <div>${businessmsg.createTime}</div>
                        </li>
                    </ul>
                    <div class="businessMsg_msg_title">
                        经营范围：
                    </div>
                    <div class="businessMsg_msg">
                        ${businessmsg.workMsg}
                    </div>
                </div>
            </div>

            <div class="comMsg_msg1">
                <div class="businessMsg_top"><span style="font-size: 30px;padding-right: 30px">公司地址</span><span
                        style="color: #adadad">${companyMsg.address}</span></div>
                <div id="address">
                </div>
            </div>

            <div class="company_job">

            </div>


        </div>
    </div>

    <%@ include file="../../asset/common/foot.jsp" %>

</div>
<script>
    var map = new BMapGL.Map("address");
    map.enableScrollWheelZoom();    //启用滚轮放大缩小，默认禁用
    var scaleCtrl = new BMapGL.ScaleControl();  // 添加比例尺控件
    map.addControl(scaleCtrl);
    var zoomCtrl = new BMapGL.ZoomControl();  // 添加缩放控件
    map.addControl(zoomCtrl);
    var cityCtrl = new BMapGL.CityListControl();  // 添加城市列表控件
    map.addControl(cityCtrl);

    // var point = new BMapGL.Point(116.331398, 39.897445);
    // map.centerAndZoom(point, 12);
    // 创建地址解析器实例
    var myGeo = new BMapGL.Geocoder();
    // 将地址解析结果显示在地图上,并调整地图视野
    myGeo.getPoint("${address}", function (point) {
        if (point) {
            map.centerAndZoom(point, 16);
            map.addOverlay(new BMapGL.Marker(point));
        } else {
            alert("您选择地址没有解析到结果!");
        }
    },);

    $(function () {
        $(".company_job").load('/dev/job/companyjobs?pageNum=1&cId='+${companyMsg.id});
    })

</script>
</body>

</html>